package com.kldy8.kldyw.system;

import android.content.Context;
import android.content.res.Resources;

import com.kldy8.kldyw.R;
import com.kldy8.kldyw.SystemSet;

import java.util.HashMap;

/**
 * Created by user on 2017/1/9.
 */

public class AccountType
{

    /**
         *摄影师	0	13   photographer
         录音师	0	12       recordinger
         剪辑师	0	11       editor
         特技人员	0	10   stunt
         化妆师(美术组)	0	9 makeup_artist
         造型师(美术组)	0	8 stylist
         灯光师/灯光指导	0	7 lighting_division
         布景师	0	6        seter
         监制	0	5        producer
         演员	0	4        actor
         原著作家	0	3    original_writer
         副导演	0	2        deputy_director
         导演	0	1        director
         其他	0	63       other

         影视公司	1	14   film_television_company
         经纪公司	1	15   brokerage_firm
         制作公司	1	16   production_company
         宣发公司	1	17    xf_company
         电影基金公司	1	  film_fund_company
         赞助单位	1	19     sponsor
         动漫公司	1	20     animation_company
         摄影公司	1	21     photography_company
         电影拷贝公司	1	22 movie_copy_company
         其他	1	64

     <string name="photographer">摄影师</string>
     <string name="recordinger">录音师</string>
     <string name="editor">剪辑师</string>
     <string name="stunt">特技人员</string>
     <string name="makeup_artist">化妆师</string>
     <string name="stylist">造型师</string>
     <string name="lighting_division">灯光师</string>
     <string name="seter">布景师</string>
     <string name="producer">监制</string>
     <string name="actor">演员</string>
     <string name="original_writer">原著作家</string>
     <string name="deputy_director">副导演</string>
     <string name="director">导演</string>
     <string name="other">其他</string>

     <string name="film_television_company">影视公司</string>
     <string name="brokerage_firm">经纪公司</string>
     <string name="production_company">制作公司</string>
     <string name="xf_company">宣发公司</string>
     <string name="film_fund_company">电影基金公司</string>
     <string name="sponsor">赞助单位</string>
     <string name="animation_company">动漫公司</string>
     <string name="photography_company">摄影公司</string>
     <string name="movie_copy_company">电影拷贝公司</string>
     <string name="other_company">其他公司</string>

     */

    HashMap<String,Integer> map;

    public AccountType(Context context)
    {
        map = new HashMap<String,Integer>();
        Resources resources = context.getResources();
        String photographer =  resources.getString(R.string.photographer);
        String recordinger =  resources.getString(R.string.recordinger);
        String editor =  resources.getString(R.string.editor);
        String stunt =  resources.getString(R.string.stunt);
        String makeup_artist =  resources.getString(R.string.makeup_artist);
        String stylist =  resources.getString(R.string.stylist);
        String lighting_division =  resources.getString(R.string.lighting_division);
        String seter =  resources.getString(R.string.seter);
        String producer =  resources.getString(R.string.producer);
        String actor =  resources.getString(R.string.actor);
        String original_writer =  resources.getString(R.string.original_writer);
        String deputy_director =  resources.getString(R.string.deputy_director);
        String director =  resources.getString(R.string.director);
        String other =  resources.getString(R.string.other);

        String film_television_company =  resources.getString(R.string.film_television_company);
        String brokerage_firm =  resources.getString(R.string.brokerage_firm);
        String production_company =  resources.getString(R.string.production_company);
        String xf_company =  resources.getString(R.string.xf_company);
        String film_fund_company =  resources.getString(R.string.film_fund_company);
        String sponsor =  resources.getString(R.string.sponsor);
        String animation_company =  resources.getString(R.string.animation_company);
        String photography_company =  resources.getString(R.string.photography_company);
        String movie_copy_company =  resources.getString(R.string.movie_copy_company);
        String other_company =  resources.getString(R.string.other_company);

        map.put(photographer,13);
        map.put(recordinger,12);
        map.put(editor,11);
        map.put(stunt,10);
        map.put(makeup_artist,9);
        map.put(stylist,8);
        map.put(lighting_division,7);
        map.put(seter,6);
        map.put(producer,5);
        map.put(actor,4);
        map.put(original_writer,3);
        map.put(deputy_director,2);
        map.put(director,1);
        map.put(other,63);

        map.put(film_television_company,14);
        map.put(brokerage_firm,15);
        map.put(production_company,16);
        map.put(xf_company,17);
        map.put(film_fund_company,18);
        map.put(sponsor,19);
        map.put(animation_company,20);
        map.put(photography_company,21);
        map.put(movie_copy_company,22);
        map.put(other_company,64);

    }

    public int returnAccountTypeId(String sth)
    {
        int result = 0;
        result =   map.get(sth);
        return  result;
    }
}
